package site.thatime.hyts.model;

public class Result {
	private boolean success;
	private int code;
	private String message;
	private Object data;

	public Result(boolean success) {
		this(success, 0);
	}

	public Result(boolean success, int code) {
		this.success = success;
		this.code = code;
	}

	public boolean isSuccess() {
		return success;
	}

	public Result setSuccess(boolean success) {
		this.success = success;
		return this;
	}

	public int getCode() {
		return code;
	}

	public Result setCode(int code) {
		this.code = code;
		return this;
	}

	public String getMessage() {
		return message;
	}

	public Result setMessage(String message) {
		this.message = message;
		return this;
	}

	public Object getData() {
		return data;
	}

	public Result setData(Object data) {
		this.data = data;
		return this;
	}

}
